using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.RazorPages;

namespace Web.Pages
{
    public class IModel : PageModel
    {
        public void OnGet(string i)
        {
            var ins = MovieSpider.Inst;
            var title = ins._Db.SelectTitleById(i);
            ViewData["Title"] = title?.FirstOrDefault().Name;
            var data = ins._Db.SelectItems(i);
            ViewData["data"] = data;

        }
    }
}
